<?php
/**
 * Created by PhpStorm.
 * User: 盛茂国
 * Tel: 18394333958
 * Date: 2020/6/2
 * Time: 10:31
 */
namespace app\api\controller;


use app\common\controller\Api;
use think\Request;

class Website extends Api
{
    protected $noNeedLogin=['index'];
    protected $noNeedRight=[];
    public function index(Request $request)
    {
        if($request->isPost()){
            $xcxconfig = db('website')->limit(1)->order('id desc')->select();
            return json(['status'=>200,'msg'=>'成功获取数据','data'=>$xcxconfig]);
        }else{
            return json(['status'=>400,'msg'=>'还没有数据']);
        }
    }
}